---
title: SAIF.Business.Claim.Legal overview
summary: High-level purpose, scope, and responsibilities for the legal-case business/domain library.
status: draft
owner: SAIF Case Management team
last_reviewed: 2026-08-21
library: SAIF.Business.Claim.Legal
reference_type: embedded
---

# SAIF.Business.Claim.Legal overview

> **Documentation context:** Front-End Application Component
> **Documented via:** Claims.BOF.Web.Legal (project reference within this repository)

SAIF.Business.Claim.Legal is the business/domain library that models and persists the legal-case aggregate and its lifecycle sub-entities for the SAIF claims Legal module, together with attorney/firm/legal-person reference-data maintenance, a REST DTO surface for a legal/claim integration API, and print/letter generation. It is the largest library in this application, with 58 `.vb` files and 96 framework-derived classes.

## Purpose
- Model, validate, and persist the legal-case aggregate (`clsLegalCase`) and its dependent sub-entities: status history, appeals and board actions, case cost and outcomes, hearings and schedules, mail dates, consolidations, acknowledgements, file locations, and case notes.
- Maintain attorney, firm, legal-person, and hearing-location reference/master data largely independent of the case aggregate, with `AddBusinessRules()`-driven validation.
- Project internal business objects into REST request/response DTO shapes for a legal/claim integration API (`LegalApi`), and support print/letter generation that assembles content from both local business objects and REST calls.
- Supply cross-cutting static code-table/lookup access (`mdlCodeTables.vb`) consumed across most domains for dropdown/code-table data.

## Responsibilities
- Enforce case-lifecycle business rules (case cost validity, duplicate-attorney checks, referential-integrity delete guards) before persisting to Oracle via `IBusinessCriteria`-driven CRUD and stored-procedure calls.
- Coordinate hybrid SQL + REST data access, since several entities (`clsLegalCase`, `clsLetterRequest(Collection)`) mix Oracle persistence with calls to the `LegalApi` integration tier.
- Integrate with `SAIF.Services.Exchange` for attorney-schedule calendar sync, gated by environment.*
- Supply reference/master data (attorneys, firms, hearing locations, legal persons) consumed by the case aggregate through foreign-key-style lookups.

## Key components
- `LegalNet\`: the legal-case aggregate and its lifecycle sub-entities (`clsLegalCase`, `clsAppeal`, `clsCaseCost`, `clsCaseNote`, `clsCaseOutcome`, `clsAcknowledge`, `clsLegalSchedule`, `clsConsolidations`, `clsLegalFileLocation`, `clsLegalCaseEvaluation`, and related collections).
- `TableMaint\`: attorney/firm/hearing-location/legal-person reference and assignment maintenance (`clsAttorneyProfile`, `clsAttorneyConflict`, `clsHearingLocation`, `clsLegalPerson`, `clsOtherFirm`, `clsOutOFTownRotationAssgn`).
- `LegalApi\`: plain REST DTO/data-transfer classes with no business logic, consumed via a REST client for cross-service reads.
- `Print\`: `clsLetterRequest(Collection)`, which assembles print-ready letter content primarily via `LegalApi` REST calls.
- `mdlCodeTables.vb`: a cross-cutting module of ~30 nested code-table lookup classes used across most domains.

## Related documentation
- [Index](index.md)
- [Architecture](architecture.md)
- [Dependencies](dependencies.md)
- [Operations and processes](operations-processes.md)
- [Business rules](business-rules.md)
- [Database tables](database-tables.md)
- [SQL catalog](sql/index.md)
- [API reference](api/index.md)

## Sources
- `SAIF.Business.Claim.Legal\SAIF.Business.Claim.Legal.vbproj`
- `SAIF.Business.Claim.Legal\LegalNet\` (all `.vb` files)
- `SAIF.Business.Claim.Legal\TableMaint\` (all `.vb` files)
- `SAIF.Business.Claim.Legal\LegalApi\` (all `.vb` files)
- `SAIF.Business.Claim.Legal\Print\clsLetterRequest.vb`, `clsLetterRequestCollection.vb`
- `SAIF.Business.Claim.Legal\mdlCodeTables.vb`
